#ifndef TT_H_
#define TT_H_

#include <vector>
#include <map>
#include <string>
#include <utility>
#include "Node.h"

class TT {

private:


	struct entry {
			int _status;
			int _quantaTotal;
			int _quantaCurrentStage; //number of messages delivered since last quantum
			int _priority;
		};

		map<Node*,entry*> _data;
		string Status(int i);

public:
	enum {READY, RUNNING, BLOCKED};
	TT(vector<Node*> nodesVec);
	virtual ~TT();
	int getStatus(Node* n);
	int getQuantaTotal(Node* n);
	int getQuantaCurrentStage(Node* n);
	int getPriority(Node* n);
	void IncCurrentStageQuanta(Node* n);
	void ResetStage(Node* n);
	void setStatus(Node* n, int s);
	void setPriority(Node* n, int p);
	void Print();

};



#endif /* TT_H_ */
